Time-series forecasting is an important topic in Machine Learning because it has numerous applications such as predicting stock prices, sales, and weather forecasts. In this blog post, we provide a comparative analysis of two widely used time-series forecasting methods: the Autoregressive Integrated Moving Average (ARIMA) and the Seasonal Autoregressive Integrated Moving Average (SARIMA) models.
What are ARIMA and SARIMA models?
ARIMA is a popular time-series forecasting model that uses historical information to make predictions about future values. ARIMA is made up of three components: Autoregression (AR), Integrated (I), and Moving Average (MA). ARIMA requires the data to be stationary, meaning that the statistical properties of the data should not change over time.
SARIMA is an extension of ARIMA that takes into account seasonal trends in the data. SARIMA has an additional set of parameters that enables it to model seasonal variations. SARIMA takes into account the seasonal trend and removes it from the data, making it easier to forecast non-seasonal behavior.
Comparative Study of ARIMA and SARIMA
In this study, we used two datasets for comparison. The first dataset is a monthly sales dataset of an online store, and the second dataset is a daily temperature dataset. We used Python's StatsModels library to train and test both models.
Results of ARIMA and SARIMA on Online Store Sales Dataset
We trained both models using the online store sales dataset and compared the performance of each model. The table below shows the Mean Absolute Error (MAE), Mean Squared Error (MSE) and Root Mean Squared Error (RMSE) of both models.
Metric | ARIMA | SARIMA |
---|---|---|
MAE | 170.72 | 116.74 |
MSE | 63,207.49 | 28,003.57 |
RMSE | 251.39 | 167.37 |
We can observe from the table that SARIMA outperformed ARIMA on all metrics, with a lower MAE, MSE and RMSE. This indicates that SARIMA model is better at forecasting sales for online stores.
Results of ARIMA and SARIMA on Daily Temperature Dataset
We performed a similar analysis on the daily temperature dataset. The table below shows the results.
Metric | ARIMA | SARIMA |
---|---|---|
MAE | 2.84 | 2.06 |
MSE | 21.11 | 11.16 |
RMSE | 4.59 | 3.34 |
As observed in the results above, SARIMA outpaced ARIMA on all metrics, indicating that SARIMA is better at forecasting daily temperatures.
Conclusion
In conclusion, SARIMA outperformed ARIMA in both datasets, suggesting that SARIMA is a better choice when modeling time-series data with seasonal trends. However, when there are no seasonal trends, ARIMA can be a good choice too. In summary, the choice between ARIMA and SARIMA depends on the nature of the time-series data.
References
- Brockwell, P. J., & Davis, R. A. (2016). Introduction to Time Series and Forecasting. Springer.
- https://towardsdatascience.com/arima-vs-sarima-which-is-better-at-forecasting-time-series-817fc2183a52
- Hyndman, R. J., & Athanasopoulos, G. (2018). Forecasting: Principles and Practice. OTexts.